const serverUrl = "http://localhost:8080/sell";
const orderPeopleNum=0;
const orderComment='';
const getTotalPrice = function(foodList) {
	// 获取物品数据
	var totalCost = 0;
	var totalNum = 0;

	for (var i in foodList) {
		totalCost += foodList[i].sellCount * foodList[i].foodPrice;
		totalNum += foodList[i].sellCount;
	}
	// 更新数据
	// this.totalNum = totalNum;
	// this.totalPrice = totalCost.toFixed(2);
	return [totalNum,totalCost.toFixed(2)]
}



export default {
	// serverUrl
	getTotalPrice,
	orderComment,
	orderPeopleNum
}
